package com.qf.task;

import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.Date;

/**
 * 定时任务 springboot
 * @author lixu
 */
@Component
public class CountAttendTask {

    /**
     * 定时任务
     */
    @Scheduled(cron = "* * * * * ?") //每S执行一次
    public void task1(){


        System.out.println("====:" + new Date());

    }
}
